package cn.wolfcode.wolf2w.domain;

import com.alibaba.fastjson.JSON;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import org.springframework.data.mongodb.core.mapping.Document;

import java.util.HashMap;
import java.util.Map;

@Setter
@Getter
@Document("spoteng")
@ToString
public class Spoteng extends BaseDomain {

    private String engname;
    private String www;
    private String traffic;
    private String tickets;
    private String opentime;
    private String info;
    private String sprotiod;

    public String getJsonString() {
        Map<String, Object> map = new HashMap<>();
        map.put("id", super.getId());
        map.put("engname", engname);
        map.put("www", www);
        map.put("traffic", traffic);
        map.put("tickets", tickets);
        map.put("opentime", opentime);
        map.put("info", info);
        map.put("sprotiod", sprotiod);
        return JSON.toJSONString(map);
    }
}
